package com.driving.single.frontend.recommend.service.impl;

import com.driving.single.common.domain.CustomSchoolRecommend;
import com.driving.single.common.entity.DrivingResult;
import com.driving.single.common.mapper.CustomRecommendMapper;
import com.driving.single.frontend.recommend.service.RecommendService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * [驾校/教练/陪练]推荐  业务层 接口实现类
 *
 * @author xsfno1
 * @version v1.0.0
 * @date 2020/2/21 21:05
 * @see com.driving.single.frontend.recommend.service.impl
 **/
@Service
public class RecommendServiceImpl implements RecommendService {
    @Resource
    private CustomRecommendMapper customRecommendMapper;

    /**
     * 获取[驾校]推荐列表
     *
     * @return {@link DrivingResult}
     */
    @Override
    public DrivingResult getSchoolRecommendService() {
        List<CustomSchoolRecommend> customSchoolRecommends = this.customRecommendMapper.selectSchoolRecommendList();
        return DrivingResult.ok(customSchoolRecommends);
    }
}
